home *** CD-ROM | disk | FTP | other *** search
/ The Games Machine 76 / XENIATGM66.iso / Indiana Jones / Indiana Jones.exe / RESOURCE / PREVIEW.GOB / cog_gen_itemdialog.cog < prev    next >
Text File  |  1999-11-15  |  1KB  |  60 lines

  1. # Jones 3D Cog Script
  2. #
  3. # gen_ItemDialog.cog
  4. #
  5. # Generic item pickup dialog
  6. #
  7. # [TRM]
  8. #
  9. # (C) 1999 LucasArts Entertainment Co. All Rights Reserved
  10. # ========================================================================================
  11.  
  12. symbols
  13.  
  14.     message     activated
  15.     
  16.     thing       player      local
  17.     thing       thingie
  18.     thing       interpCam
  19.     
  20.     sound       snd_Thingie=
  21.     
  22.     int         gotIt=0     local
  23.     
  24. end
  25.  
  26. # ========================================================================================
  27.  
  28. code
  29.  
  30. activated:
  31.  
  32.     player = GetLocalPlayerThing();
  33.     
  34.     if((GetSenderRef() == thingie) && (gotIt == 0))
  35.     {
  36.         #Print("activated");
  37.         gotIt = 1;
  38.         
  39.         # disable the player
  40.         SetActorFlags(player, 0x200000);
  41.         StopThing(player);
  42.         
  43.         # offset camera
  44.         SetExtCamOffsetToThing(interpCam);
  45.         Sleep(1.0);
  46.         
  47.         PlayVoice(player, snd_Thingie, 1.0, 1);
  48.         
  49.         Sleep(1.0);
  50.         ClearActorFlags(player, 0x200000);
  51.         RestoreExtCam();
  52.     }
  53.         
  54.     return;
  55.  
  56. # ========================================================================================
  57.  
  58. end
  59.  
  60.